import { get, postData } from "@/api/request"
import { ResponseData, LoginParam, CryptoKeyResponse} from "@/types/type"

export const getCryptoKey = () => {
    return get<ResponseData<CryptoKeyResponse>>('/auth/getCryptoKey');
}

export const login = (params: LoginParam) => {
    return postData<ResponseData<string>>('/auth/login', params);
}

export const logout = () => {
    return postData<ResponseData<string>>('/auth/logout');
}
